using System.Collections.Generic;
using System.Web.UI.WebControls;
using ValidationFramework.Reflection;

namespace ValidationFramework.Web.ASP
{
    public interface IClientValidationGenerator : IStrategy<RuleContext>
    {

        /// <summary>
        /// Get a list of <see cref="BaseValidator"/>s to perform the client side validation.
        /// </summary>
        /// <remarks>The <see cref="BaseValidator"/>s returned should only perform client validation.</remarks>
        /// <returns>The<see cref="IList{T}"/> of <see cref="BaseValidator"/>s to perform the client side validation.</returns>
        IList<BaseValidator> CreateWebClientValidators(Rule rule, InfoDescriptor infoDescriptor);
    }

    public class RuleContext
    {
        public Rule Rule{ get;set;}

        public InfoDescriptor InfoDescriptor { get; set; }
    }
}